﻿@page "/rates"
@inject IStringLocalizer<Rates> Localizer

<h3>@Localizer["Title"]</h3>

<h4>@Localizer["H1"]</h4>

<Block Title="@Localizer["Blcok1Title"]" Introduction="@Localizer["Blcok1Intro"]">
    <Rate Value="@BindValue" ValueChanged="@OnValueChanged" />
    <BlockLogger @ref="Trace" class="mt-3" />
</Block>

<Block Title="@Localizer["Blcok2Title"]" Introduction="@Localizer["Blcok2Intro"]">
    <div class="row g-3">
        <div class="col-6">
            <Rate Value="@BindValue1" IsDisable="IsDisable" />
        </div>
        <div class="col-6">
            <Switch @bind-Value="IsDisable" OnText="@Localizer["SwitchOn"]" OnColor="Color.Danger" OffText="@Localizer["SwitchOff"]" OffColor="@Color.Success" />
        </div>
    </div>
</Block>

<AttributeTable Items="@GetAttributes()" />

<EventTable Items="@GetEvents()" />
